<#import "/spring.ftl" as spring />
<html>
<head>
    <title>
    ${springMacroRequestContext.getMessage("hole")}&nbsp;
    <#if RequestParameters.id??>
    ${springMacroRequestContext.getMessage("entity.edit")}
        <#else>
        ${springMacroRequestContext.getMessage("entity.createNew")}
    </#if></title>
</head>
<body>
<h1>${springMacroRequestContext.getMessage("hole")}&nbsp;
<#if RequestParameters.id??>
${springMacroRequestContext.getMessage("entity.edit")}
    <#else>
    ${springMacroRequestContext.getMessage("entity.createNew")}
</#if>
</h1>

<div>
    <a href="viewAll.htm"><@spring.message "entity.viewAll"/></a>
</div>
<div class="marginTop infoBox">
    <form action="save.htm" method="POST">
        <table>
            <tr>
            <@spring.bind "entity.course" />
                <td class="formRowLabel"><@spring.message "course"/>:</td>
                <input type="hidden"
                       name="${spring.status.expression}"
                       value="${course.id}"/><br>
                <td>${course.guiDescription}</td>
                <td></td>
            </tr>
            <tr>
                <td class="formRowLabel"><@spring.message "hole.orderOnCourse"/>*:</td>
                <td><@spring.formInput "entity.orderOnCourse"/></td>
                <td><@spring.showErrors "<br>"/></td>
            </tr>
            <tr>
                <td class="formRowLabel"><@spring.message "hole.slopeIndex"/>*:</td>
                <td><@spring.formInput "entity.slopeIndex"/></td>
                <td><@spring.showErrors "<br>"/></td>
            </tr>
            <tr>
                <td class="formRowLabel"><@spring.message "hole.par"/>*:</td>
                <td><@spring.formInput "entity.par"/></td>
                <td><@spring.showErrors "<br>"/></td>
            </tr>
            <tr>
                <td class="formRowLabel"><@spring.message "entity.description"/>*:</td>
                <td><@spring.formInput "entity.description"/></td>
                <td><@spring.showErrors "<br>"/></td>
            </tr>
            <tr>
                <td class="formRowLabel"><@spring.message "entity.name"/>*:</td>
                <td><@spring.formInput "entity.name"/></td>
                <td><@spring.showErrors "<br>"/></td>
            </tr>
            <tr>
                <td colspan="3">
                    <input type="submit" value="<@spring.message "entity.save"/>"/>
                </td>
            </tr>
        </table>
    </form>
</div>
</body>
</html>